<template>
    <van-swipe class="my-swipe" :autoplay="3000" indicator-color="white">
        <van-swipe-item v-for="item, index in list" :key="index">
            <slot :item="item" :index="index"></slot>
            <!-- <img :src="typeof item == 'string' ? item : item.url " alt=""> -->
        </van-swipe-item>
    </van-swipe>
</template>
  
<script setup lang="ts">
import { VagueOject } from "@/types/common";

withDefaults(defineProps<{
    list: VagueOject[] | string[]
}>(), {
    list: () => []
})

</script>
  
<style lang="less" scoped>
.van-swipe {
    img {
        width: 100%;
    }
}
</style>
